function [ scaled_image ] = my_crop_iterative( image, width, height, x, y )
    imgmax = double(max(image(:)));
    cropped_image = zeros(height, width);
    for i = 1:1:height
        for j = 1:1:width
            cropped_image(i, j) = double(image(i + x - 1, j + y - 1)) / imgmax;
        end
    end
    h = uint32(height / 3 - 1);
    w = uint32(width / 3 - 1);
    scaled_image = zeros(h, w);
    for i = 1:1:h
        for j = 1:1:w
            scaled_image(i, j) = cropped_image(i*3, j*3);
        end
    end
end

